<?php
$tdatacommercial_invoice_items=array();
	$tdatacommercial_invoice_items[".NumberOfChars"]=80; 
	$tdatacommercial_invoice_items[".ShortName"]="commercial_invoice_items";
	$tdatacommercial_invoice_items[".OwnerID"]="";
	$tdatacommercial_invoice_items[".OriginalTable"]="commercial_invoice_items";


	
//	field labels
$fieldLabelscommercial_invoice_items = array();
if(mlang_getcurrentlang()=="English")
{
	$fieldLabelscommercial_invoice_items["English"]=array();
	$fieldToolTipscommercial_invoice_items["English"]=array();
	$fieldLabelscommercial_invoice_items["English"]["id"] = "Id";
	$fieldToolTipscommercial_invoice_items["English"]["id"] = "";
	$fieldLabelscommercial_invoice_items["English"]["commercial_invoice_id"] = "Commercial Invoice ";
	$fieldToolTipscommercial_invoice_items["English"]["commercial_invoice_id"] = "";
	$fieldLabelscommercial_invoice_items["English"]["packages"] = "Packages";
	$fieldToolTipscommercial_invoice_items["English"]["packages"] = "";
	$fieldLabelscommercial_invoice_items["English"]["quantity"] = "Quantity";
	$fieldToolTipscommercial_invoice_items["English"]["quantity"] = "";
	$fieldLabelscommercial_invoice_items["English"]["net_weight"] = "Net Weight";
	$fieldToolTipscommercial_invoice_items["English"]["net_weight"] = "";
	$fieldLabelscommercial_invoice_items["English"]["gross_weight"] = "Gross Weight";
	$fieldToolTipscommercial_invoice_items["English"]["gross_weight"] = "";
	$fieldLabelscommercial_invoice_items["English"]["description"] = "Description";
	$fieldToolTipscommercial_invoice_items["English"]["description"] = "";
	$fieldLabelscommercial_invoice_items["English"]["unit_price"] = "Unit Price";
	$fieldToolTipscommercial_invoice_items["English"]["unit_price"] = "";
	$fieldLabelscommercial_invoice_items["English"]["total_value"] = "Total Value";
	$fieldToolTipscommercial_invoice_items["English"]["total_value"] = "";
	if (count($fieldToolTipscommercial_invoice_items["English"])){
		$tdatacommercial_invoice_items[".isUseToolTips"]=true;
	}
}
if(mlang_getcurrentlang()=="Chinese (Hong Kong S.A.R.)")
{
	$fieldLabelscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]=array();
	$fieldToolTipscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]=array();
	$fieldLabelscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["id"] = "Id";
	$fieldToolTipscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["id"] = "";
	$fieldLabelscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["commercial_invoice_id"] = "Commercial Invoice Id";
	$fieldToolTipscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["commercial_invoice_id"] = "";
	$fieldLabelscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["packages"] = "Packages";
	$fieldToolTipscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["packages"] = "";
	$fieldLabelscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["quantity"] = "Quantity";
	$fieldToolTipscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["quantity"] = "";
	$fieldLabelscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["net_weight"] = "Net Weight";
	$fieldToolTipscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["net_weight"] = "";
	$fieldLabelscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["gross_weight"] = "Gross Weight";
	$fieldToolTipscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["gross_weight"] = "";
	$fieldLabelscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["description"] = "Description";
	$fieldToolTipscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["description"] = "";
	$fieldLabelscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["unit_price"] = "Unit Price";
	$fieldToolTipscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["unit_price"] = "";
	$fieldLabelscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["total_value"] = "Total Value";
	$fieldToolTipscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"]["total_value"] = "";
	if (count($fieldToolTipscommercial_invoice_items["Chinese (Hong Kong S.A.R.)"])){
		$tdatacommercial_invoice_items[".isUseToolTips"]=true;
	}
}
if(mlang_getcurrentlang()=="Chinese (Taiwan)")
{
	$fieldLabelscommercial_invoice_items["Chinese (Taiwan)"]=array();
	$fieldToolTipscommercial_invoice_items["Chinese (Taiwan)"]=array();
	$fieldLabelscommercial_invoice_items["Chinese (Taiwan)"]["id"] = "Id";
	$fieldToolTipscommercial_invoice_items["Chinese (Taiwan)"]["id"] = "";
	$fieldLabelscommercial_invoice_items["Chinese (Taiwan)"]["commercial_invoice_id"] = "Commercial Invoice Id";
	$fieldToolTipscommercial_invoice_items["Chinese (Taiwan)"]["commercial_invoice_id"] = "";
	$fieldLabelscommercial_invoice_items["Chinese (Taiwan)"]["packages"] = "Packages";
	$fieldToolTipscommercial_invoice_items["Chinese (Taiwan)"]["packages"] = "";
	$fieldLabelscommercial_invoice_items["Chinese (Taiwan)"]["quantity"] = "Quantity";
	$fieldToolTipscommercial_invoice_items["Chinese (Taiwan)"]["quantity"] = "";
	$fieldLabelscommercial_invoice_items["Chinese (Taiwan)"]["net_weight"] = "Net Weight";
	$fieldToolTipscommercial_invoice_items["Chinese (Taiwan)"]["net_weight"] = "";
	$fieldLabelscommercial_invoice_items["Chinese (Taiwan)"]["gross_weight"] = "Gross Weight";
	$fieldToolTipscommercial_invoice_items["Chinese (Taiwan)"]["gross_weight"] = "";
	$fieldLabelscommercial_invoice_items["Chinese (Taiwan)"]["description"] = "Description";
	$fieldToolTipscommercial_invoice_items["Chinese (Taiwan)"]["description"] = "";
	$fieldLabelscommercial_invoice_items["Chinese (Taiwan)"]["unit_price"] = "Unit Price";
	$fieldToolTipscommercial_invoice_items["Chinese (Taiwan)"]["unit_price"] = "";
	$fieldLabelscommercial_invoice_items["Chinese (Taiwan)"]["total_value"] = "Total Value";
	$fieldToolTipscommercial_invoice_items["Chinese (Taiwan)"]["total_value"] = "";
	if (count($fieldToolTipscommercial_invoice_items["Chinese (Taiwan)"])){
		$tdatacommercial_invoice_items[".isUseToolTips"]=true;
	}
}
if(mlang_getcurrentlang()=="French")
{
	$fieldLabelscommercial_invoice_items["French"]=array();
	$fieldToolTipscommercial_invoice_items["French"]=array();
	$fieldLabelscommercial_invoice_items["French"]["id"] = "Id";
	$fieldToolTipscommercial_invoice_items["French"]["id"] = "";
	$fieldLabelscommercial_invoice_items["French"]["commercial_invoice_id"] = "Commercial Invoice Id";
	$fieldToolTipscommercial_invoice_items["French"]["commercial_invoice_id"] = "";
	$fieldLabelscommercial_invoice_items["French"]["packages"] = "Packages";
	$fieldToolTipscommercial_invoice_items["French"]["packages"] = "";
	$fieldLabelscommercial_invoice_items["French"]["quantity"] = "Quantity";
	$fieldToolTipscommercial_invoice_items["French"]["quantity"] = "";
	$fieldLabelscommercial_invoice_items["French"]["net_weight"] = "Net Weight";
	$fieldToolTipscommercial_invoice_items["French"]["net_weight"] = "";
	$fieldLabelscommercial_invoice_items["French"]["gross_weight"] = "Gross Weight";
	$fieldToolTipscommercial_invoice_items["French"]["gross_weight"] = "";
	$fieldLabelscommercial_invoice_items["French"]["description"] = "Description";
	$fieldToolTipscommercial_invoice_items["French"]["description"] = "";
	$fieldLabelscommercial_invoice_items["French"]["unit_price"] = "Unit Price";
	$fieldToolTipscommercial_invoice_items["French"]["unit_price"] = "";
	$fieldLabelscommercial_invoice_items["French"]["total_value"] = "Total Value";
	$fieldToolTipscommercial_invoice_items["French"]["total_value"] = "";
	if (count($fieldToolTipscommercial_invoice_items["French"])){
		$tdatacommercial_invoice_items[".isUseToolTips"]=true;
	}
}


	
	$tdatacommercial_invoice_items[".NCSearch"]=true;

	

$tdatacommercial_invoice_items[".shortTableName"] = "commercial_invoice_items";
$tdatacommercial_invoice_items[".nSecOptions"] = 0;
$tdatacommercial_invoice_items[".recsPerRowList"] = 1;	
$tdatacommercial_invoice_items[".tableGroupBy"] = "0";
$tdatacommercial_invoice_items[".mainTableOwnerID"] = "";
$tdatacommercial_invoice_items[".moveNext"] = 1;




$tdatacommercial_invoice_items[".showAddInPopup"] = false;

$tdatacommercial_invoice_items[".showEditInPopup"] = false;

$tdatacommercial_invoice_items[".showViewInPopup"] = false;


$tdatacommercial_invoice_items[".fieldsForRegister"] = array();

$tdatacommercial_invoice_items[".listAjax"] = true;

	$tdatacommercial_invoice_items[".audit"] = false;

	$tdatacommercial_invoice_items[".locking"] = false;
	
$tdatacommercial_invoice_items[".listIcons"] = true;
$tdatacommercial_invoice_items[".edit"] = true;
$tdatacommercial_invoice_items[".inlineEdit"] = true;
$tdatacommercial_invoice_items[".copy"] = true;
$tdatacommercial_invoice_items[".view"] = true;

$tdatacommercial_invoice_items[".exportTo"] = true;

$tdatacommercial_invoice_items[".printFriendly"] = true;

$tdatacommercial_invoice_items[".delete"] = true;

$tdatacommercial_invoice_items[".showSimpleSearchOptions"] = true;

$tdatacommercial_invoice_items[".showSearchPanel"] = true;


$tdatacommercial_invoice_items[".isUseAjaxSuggest"] = true;

$tdatacommercial_invoice_items[".rowHighlite"] = true;


// button handlers file names

$tdatacommercial_invoice_items[".addPageEvents"] = false;

$tdatacommercial_invoice_items[".arrKeyFields"][] = "id";

// use datepicker for search panel
$tdatacommercial_invoice_items[".isUseCalendarForSearch"] = false;

// use timepicker for search panel
$tdatacommercial_invoice_items[".isUseTimeForSearch"] = false;

$tdatacommercial_invoice_items[".isUseiBox"] = false;



$tdatacommercial_invoice_items[".isUseInlineAdd"] = true;

$tdatacommercial_invoice_items[".isUseInlineEdit"] = true;
$tdatacommercial_invoice_items[".isUseInlineJs"] = $tdatacommercial_invoice_items[".isUseInlineAdd"] || $tdatacommercial_invoice_items[".isUseInlineEdit"];

$tdatacommercial_invoice_items[".allSearchFields"] = array();

$tdatacommercial_invoice_items[".globSearchFields"][] = "id";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("id", $tdatacommercial_invoice_items[".allSearchFields"]))
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "id";	
}
$tdatacommercial_invoice_items[".globSearchFields"][] = "commercial_invoice_id";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("commercial_invoice_id", $tdatacommercial_invoice_items[".allSearchFields"]))
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "commercial_invoice_id";	
}
$tdatacommercial_invoice_items[".globSearchFields"][] = "packages";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("packages", $tdatacommercial_invoice_items[".allSearchFields"]))
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "packages";	
}
$tdatacommercial_invoice_items[".globSearchFields"][] = "quantity";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("quantity", $tdatacommercial_invoice_items[".allSearchFields"]))
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "quantity";	
}
$tdatacommercial_invoice_items[".globSearchFields"][] = "net_weight";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("net_weight", $tdatacommercial_invoice_items[".allSearchFields"]))
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "net_weight";	
}
$tdatacommercial_invoice_items[".globSearchFields"][] = "gross_weight";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("gross_weight", $tdatacommercial_invoice_items[".allSearchFields"]))
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "gross_weight";	
}
$tdatacommercial_invoice_items[".globSearchFields"][] = "description";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("description", $tdatacommercial_invoice_items[".allSearchFields"]))
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "description";	
}
$tdatacommercial_invoice_items[".globSearchFields"][] = "unit_price";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("unit_price", $tdatacommercial_invoice_items[".allSearchFields"]))
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "unit_price";	
}
$tdatacommercial_invoice_items[".globSearchFields"][] = "total_value";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("total_value", $tdatacommercial_invoice_items[".allSearchFields"]))
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "total_value";	
}


$tdatacommercial_invoice_items[".googleLikeFields"][] = "id";
$tdatacommercial_invoice_items[".googleLikeFields"][] = "commercial_invoice_id";
$tdatacommercial_invoice_items[".googleLikeFields"][] = "packages";
$tdatacommercial_invoice_items[".googleLikeFields"][] = "quantity";
$tdatacommercial_invoice_items[".googleLikeFields"][] = "net_weight";
$tdatacommercial_invoice_items[".googleLikeFields"][] = "gross_weight";
$tdatacommercial_invoice_items[".googleLikeFields"][] = "description";
$tdatacommercial_invoice_items[".googleLikeFields"][] = "unit_price";
$tdatacommercial_invoice_items[".googleLikeFields"][] = "total_value";



$tdatacommercial_invoice_items[".advSearchFields"][] = "id";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("id", $tdatacommercial_invoice_items[".allSearchFields"])) 
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "id";	
}
$tdatacommercial_invoice_items[".advSearchFields"][] = "commercial_invoice_id";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("commercial_invoice_id", $tdatacommercial_invoice_items[".allSearchFields"])) 
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "commercial_invoice_id";	
}
$tdatacommercial_invoice_items[".advSearchFields"][] = "packages";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("packages", $tdatacommercial_invoice_items[".allSearchFields"])) 
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "packages";	
}
$tdatacommercial_invoice_items[".advSearchFields"][] = "quantity";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("quantity", $tdatacommercial_invoice_items[".allSearchFields"])) 
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "quantity";	
}
$tdatacommercial_invoice_items[".advSearchFields"][] = "net_weight";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("net_weight", $tdatacommercial_invoice_items[".allSearchFields"])) 
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "net_weight";	
}
$tdatacommercial_invoice_items[".advSearchFields"][] = "gross_weight";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("gross_weight", $tdatacommercial_invoice_items[".allSearchFields"])) 
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "gross_weight";	
}
$tdatacommercial_invoice_items[".advSearchFields"][] = "description";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("description", $tdatacommercial_invoice_items[".allSearchFields"])) 
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "description";	
}
$tdatacommercial_invoice_items[".advSearchFields"][] = "unit_price";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("unit_price", $tdatacommercial_invoice_items[".allSearchFields"])) 
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "unit_price";	
}
$tdatacommercial_invoice_items[".advSearchFields"][] = "total_value";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("total_value", $tdatacommercial_invoice_items[".allSearchFields"])) 
{
	$tdatacommercial_invoice_items[".allSearchFields"][] = "total_value";	
}

$tdatacommercial_invoice_items[".isTableType"] = "list";


	

$tdatacommercial_invoice_items[".isDisplayLoading"] = true;

$tdatacommercial_invoice_items[".isResizeColumns"] = false;





$tdatacommercial_invoice_items[".pageSize"] = 20;

$gstrOrderBy = "";
if(strlen($gstrOrderBy) && strtolower(substr($gstrOrderBy,0,8))!="order by")
	$gstrOrderBy = "order by ".$gstrOrderBy;
$tdatacommercial_invoice_items[".strOrderBy"] = $gstrOrderBy;
	
$tdatacommercial_invoice_items[".orderindexes"] = array();

$tdatacommercial_invoice_items[".sqlHead"] = "SELECT id,   commercial_invoice_id,   packages,   quantity,   net_weight,   gross_weight,   description,   unit_price,   total_value";
$tdatacommercial_invoice_items[".sqlFrom"] = "FROM commercial_invoice_items";
$tdatacommercial_invoice_items[".sqlWhereExpr"] = "";
$tdatacommercial_invoice_items[".sqlTail"] = "";




//fill array of records per page for list and report without group fields
$arrRPP = array();
$arrRPP[] = 10;
$arrRPP[] = 20;
$arrRPP[] = 30;
$arrRPP[] = 50;
$arrRPP[] = 100;
$arrRPP[] = 500;
$arrRPP[] = -1;
$tdatacommercial_invoice_items[".arrRecsPerPage"] = $arrRPP;

//fill array of groups per page for report with group fields
$arrGPP = array();
$arrGPP[] = 1;
$arrGPP[] = 3;
$arrGPP[] = 5;
$arrGPP[] = 10;
$arrGPP[] = 50;
$arrGPP[] = 100;
$arrGPP[] = -1;
$tdatacommercial_invoice_items[".arrGroupsPerPage"] = $arrGPP;

	$tableKeys = array();
	$tableKeys[] = "id";
	$tdatacommercial_invoice_items[".Keys"] = $tableKeys;

//	id
	$fdata = array();
	$fdata["strName"] = "id";
	$fdata["ownerTable"] = "commercial_invoice_items";
		$fdata["Label"]="Id"; 
	
		
		
	$fdata["FieldType"]= 3;
	
		$fdata["AutoInc"]=true;
	
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "id";
	
		$fdata["FullName"]= "id";
	
		$fdata["IsRequired"]=true; 
	
		
		
		
		
				$fdata["Index"]= 1;
				$fdata["EditParams"]="";
			
		
		
		
		
		
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
				$fdata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");	
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdatacommercial_invoice_items["id"]=$fdata;
//	commercial_invoice_id
	$fdata = array();
	$fdata["strName"] = "commercial_invoice_id";
	$fdata["ownerTable"] = "commercial_invoice_items";
		$fdata["Label"]="Commercial Invoice "; 
	
		
		
	$fdata["FieldType"]= 3;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Lookup wizard";
	$fdata["ViewFormat"]= "";
	
		
		$fdata["LookupType"]=1;
	$fdata["pLookupType"] = 1;
	$fdata["freeInput"] = 0;	
	$fdata["autoCompleteFieldsOnEdit"] = 0;
	$fdata["autoCompleteFields"] = array();
										$fdata["LinkField"]="id";
	$fdata["LinkFieldType"]=3;
	$fdata["DisplayField"]="id";
				$fdata["LookupTable"]="commercial_invoices";
	$fdata["LookupOrderBy"]="";
																			
					
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "commercial_invoice_id";
	
		$fdata["FullName"]= "commercial_invoice_id";
	
		$fdata["IsRequired"]=true; 
	
		
		
		
		
				$fdata["Index"]= 2;
				
		
		$fdata["bAddPage"]=true; 
	
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdatacommercial_invoice_items["commercial_invoice_id"]=$fdata;
//	packages
	$fdata = array();
	$fdata["strName"] = "packages";
	$fdata["ownerTable"] = "commercial_invoice_items";
		$fdata["Label"]="Packages"; 
	
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "packages";
	
		$fdata["FullName"]= "packages";
	
		
		
		
		
		
				$fdata["Index"]= 3;
				$fdata["EditParams"]="";
			$fdata["EditParams"].= " maxlength=45";
		
		$fdata["bListPage"]=true; 
	
		$fdata["bAddPage"]=true; 
	
		$fdata["bInlineAdd"]=true; 
	
		$fdata["bEditPage"]=true; 
	
		$fdata["bInlineEdit"]=true; 
	
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdatacommercial_invoice_items["packages"]=$fdata;
//	quantity
	$fdata = array();
	$fdata["strName"] = "quantity";
	$fdata["ownerTable"] = "commercial_invoice_items";
		$fdata["Label"]="Quantity"; 
	
		
		
	$fdata["FieldType"]= 3;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "quantity";
	
		$fdata["FullName"]= "quantity";
	
		
		
		
		
		
				$fdata["Index"]= 4;
				$fdata["EditParams"]="";
			
		$fdata["bListPage"]=true; 
	
		$fdata["bAddPage"]=true; 
	
		$fdata["bInlineAdd"]=true; 
	
		$fdata["bEditPage"]=true; 
	
		$fdata["bInlineEdit"]=true; 
	
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
				$fdata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");	
						
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdatacommercial_invoice_items["quantity"]=$fdata;
//	net_weight
	$fdata = array();
	$fdata["strName"] = "net_weight";
	$fdata["ownerTable"] = "commercial_invoice_items";
		$fdata["Label"]="Net Weight"; 
	
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "net_weight";
	
		$fdata["FullName"]= "net_weight";
	
		
		
		
		
		
				$fdata["Index"]= 5;
				$fdata["EditParams"]="";
			$fdata["EditParams"].= " maxlength=255";
		
		$fdata["bListPage"]=true; 
	
		$fdata["bAddPage"]=true; 
	
		$fdata["bInlineAdd"]=true; 
	
		$fdata["bEditPage"]=true; 
	
		$fdata["bInlineEdit"]=true; 
	
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdatacommercial_invoice_items["net_weight"]=$fdata;
//	gross_weight
	$fdata = array();
	$fdata["strName"] = "gross_weight";
	$fdata["ownerTable"] = "commercial_invoice_items";
		$fdata["Label"]="Gross Weight"; 
	
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "gross_weight";
	
		$fdata["FullName"]= "gross_weight";
	
		
		
		
		
		
				$fdata["Index"]= 6;
				$fdata["EditParams"]="";
			$fdata["EditParams"].= " maxlength=45";
		
		$fdata["bListPage"]=true; 
	
		$fdata["bAddPage"]=true; 
	
		$fdata["bInlineAdd"]=true; 
	
		$fdata["bEditPage"]=true; 
	
		$fdata["bInlineEdit"]=true; 
	
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdatacommercial_invoice_items["gross_weight"]=$fdata;
//	description
	$fdata = array();
	$fdata["strName"] = "description";
	$fdata["ownerTable"] = "commercial_invoice_items";
		$fdata["Label"]="Description"; 
	
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text area";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "description";
	
		$fdata["FullName"]= "description";
	
		
		
		
		
		
				$fdata["Index"]= 7;
			$fdata["EditParams"] = "";
			$fdata["EditParams"].= " rows=100";
		$fdata["nRows"] = 100;
			$fdata["EditParams"].= " cols=200";
		$fdata["nCols"] = 200;
		
		$fdata["bListPage"]=true; 
	
		$fdata["bAddPage"]=true; 
	
		$fdata["bInlineAdd"]=true; 
	
		$fdata["bEditPage"]=true; 
	
		$fdata["bInlineEdit"]=true; 
	
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdatacommercial_invoice_items["description"]=$fdata;
//	unit_price
	$fdata = array();
	$fdata["strName"] = "unit_price";
	$fdata["ownerTable"] = "commercial_invoice_items";
		$fdata["Label"]="Unit Price"; 
	
		
		
	$fdata["FieldType"]= 14;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "Number";
	
		
		
		
		$fdata["DecimalDigits"] = 2;
	
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "unit_price";
	
		$fdata["FullName"]= "unit_price";
	
		
		
		
		
		
				$fdata["Index"]= 8;
				$fdata["EditParams"]="";
			
		$fdata["bListPage"]=true; 
	
		$fdata["bAddPage"]=true; 
	
		$fdata["bInlineAdd"]=true; 
	
		$fdata["bEditPage"]=true; 
	
		$fdata["bInlineEdit"]=true; 
	
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
				$fdata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");	
						
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdatacommercial_invoice_items["unit_price"]=$fdata;
//	total_value
	$fdata = array();
	$fdata["strName"] = "total_value";
	$fdata["ownerTable"] = "commercial_invoice_items";
		$fdata["Label"]="Total Value"; 
	
		
		
	$fdata["FieldType"]= 14;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "Custom";
	
		
		
		
		
		
	$fdata["GoodName"]= "total_value";
	
		$fdata["FullName"]= "total_value";
	
		
		
		
		
		
				$fdata["Index"]= 9;
				$fdata["EditParams"]="";
			
		$fdata["bListPage"]=true; 
	
		$fdata["bAddPage"]=true; 
	
		$fdata["bInlineAdd"]=true; 
	
		$fdata["bEditPage"]=true; 
	
		$fdata["bInlineEdit"]=true; 
	
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
				$fdata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");	
						
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdatacommercial_invoice_items["total_value"]=$fdata;

	
$tables_data["commercial_invoice_items"]=&$tdatacommercial_invoice_items;
$field_labels["commercial_invoice_items"] = &$fieldLabelscommercial_invoice_items;
$fieldToolTips["commercial_invoice_items"] = &$fieldToolTipscommercial_invoice_items;

// -----------------start  prepare master-details data arrays ------------------------------//
// tables which are detail tables for current table (master)
$detailsTablesData["commercial_invoice_items"] = array();

	
// tables which are master tables for current table (detail)
$masterTablesData["commercial_invoice_items"] = array();

$mIndex = 1-1;
			$strOriginalDetailsTable="commercial_invoices";
	$masterTablesData["commercial_invoice_items"][$mIndex] = array(
		  "mDataSourceTable"=>"commercial_invoices"
		, "mOriginalTable" => $strOriginalDetailsTable
		, "mShortTable" => "commercial_invoices"
		, "masterKeys" => array()
		, "detailKeys" => array()
		, "dispChildCount" => "1"
		, "hideChild" => "0"	
		, "dispInfo" => "1"								
		, "previewOnList" => 1
		, "previewOnAdd" => 1
		, "previewOnEdit" => 1
		, "previewOnView" => 1
	);	
		$masterTablesData["commercial_invoice_items"][$mIndex]["masterKeys"][]="id";
		$masterTablesData["commercial_invoice_items"][$mIndex]["detailKeys"][]="commercial_invoice_id";

// -----------------end  prepare master-details data arrays ------------------------------//

require_once(getabspath("classes/sql.php"));










$proto571=array();
$proto571["m_strHead"] = "SELECT";
$proto571["m_strFieldList"] = "id,   commercial_invoice_id,   packages,   quantity,   net_weight,   gross_weight,   description,   unit_price,   total_value";
$proto571["m_strFrom"] = "FROM commercial_invoice_items";
$proto571["m_strWhere"] = "";
$proto571["m_strOrderBy"] = "";
$proto571["m_strTail"] = "";
$proto572=array();
$proto572["m_sql"] = "";
$proto572["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

$proto572["m_column"]=$obj;
$proto572["m_contained"] = array();
$proto572["m_strCase"] = "";
$proto572["m_havingmode"] = "0";
$proto572["m_inBrackets"] = "0";
$proto572["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto572);

$proto571["m_where"] = $obj;
$proto574=array();
$proto574["m_sql"] = "";
$proto574["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

$proto574["m_column"]=$obj;
$proto574["m_contained"] = array();
$proto574["m_strCase"] = "";
$proto574["m_havingmode"] = "0";
$proto574["m_inBrackets"] = "0";
$proto574["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto574);

$proto571["m_having"] = $obj;
$proto571["m_fieldlist"] = array();
						$proto576=array();
			$obj = new SQLField(array(
	"m_strName" => "id",
	"m_strTable" => "commercial_invoice_items"
));

$proto576["m_expr"]=$obj;
$proto576["m_alias"] = "";
$obj = new SQLFieldListItem($proto576);

$proto571["m_fieldlist"][]=$obj;
						$proto578=array();
			$obj = new SQLField(array(
	"m_strName" => "commercial_invoice_id",
	"m_strTable" => "commercial_invoice_items"
));

$proto578["m_expr"]=$obj;
$proto578["m_alias"] = "";
$obj = new SQLFieldListItem($proto578);

$proto571["m_fieldlist"][]=$obj;
						$proto580=array();
			$obj = new SQLField(array(
	"m_strName" => "packages",
	"m_strTable" => "commercial_invoice_items"
));

$proto580["m_expr"]=$obj;
$proto580["m_alias"] = "";
$obj = new SQLFieldListItem($proto580);

$proto571["m_fieldlist"][]=$obj;
						$proto582=array();
			$obj = new SQLField(array(
	"m_strName" => "quantity",
	"m_strTable" => "commercial_invoice_items"
));

$proto582["m_expr"]=$obj;
$proto582["m_alias"] = "";
$obj = new SQLFieldListItem($proto582);

$proto571["m_fieldlist"][]=$obj;
						$proto584=array();
			$obj = new SQLField(array(
	"m_strName" => "net_weight",
	"m_strTable" => "commercial_invoice_items"
));

$proto584["m_expr"]=$obj;
$proto584["m_alias"] = "";
$obj = new SQLFieldListItem($proto584);

$proto571["m_fieldlist"][]=$obj;
						$proto586=array();
			$obj = new SQLField(array(
	"m_strName" => "gross_weight",
	"m_strTable" => "commercial_invoice_items"
));

$proto586["m_expr"]=$obj;
$proto586["m_alias"] = "";
$obj = new SQLFieldListItem($proto586);

$proto571["m_fieldlist"][]=$obj;
						$proto588=array();
			$obj = new SQLField(array(
	"m_strName" => "description",
	"m_strTable" => "commercial_invoice_items"
));

$proto588["m_expr"]=$obj;
$proto588["m_alias"] = "";
$obj = new SQLFieldListItem($proto588);

$proto571["m_fieldlist"][]=$obj;
						$proto590=array();
			$obj = new SQLField(array(
	"m_strName" => "unit_price",
	"m_strTable" => "commercial_invoice_items"
));

$proto590["m_expr"]=$obj;
$proto590["m_alias"] = "";
$obj = new SQLFieldListItem($proto590);

$proto571["m_fieldlist"][]=$obj;
						$proto592=array();
			$obj = new SQLField(array(
	"m_strName" => "total_value",
	"m_strTable" => "commercial_invoice_items"
));

$proto592["m_expr"]=$obj;
$proto592["m_alias"] = "";
$obj = new SQLFieldListItem($proto592);

$proto571["m_fieldlist"][]=$obj;
$proto571["m_fromlist"] = array();
												$proto594=array();
$proto594["m_link"] = "SQLL_MAIN";
			$proto595=array();
$proto595["m_strName"] = "commercial_invoice_items";
$proto595["m_columns"] = array();
$proto595["m_columns"][] = "id";
$proto595["m_columns"][] = "commercial_invoice_id";
$proto595["m_columns"][] = "packages";
$proto595["m_columns"][] = "quantity";
$proto595["m_columns"][] = "net_weight";
$proto595["m_columns"][] = "gross_weight";
$proto595["m_columns"][] = "description";
$proto595["m_columns"][] = "unit_price";
$proto595["m_columns"][] = "total_value";
$obj = new SQLTable($proto595);

$proto594["m_table"] = $obj;
$proto594["m_alias"] = "";
$proto596=array();
$proto596["m_sql"] = "";
$proto596["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

$proto596["m_column"]=$obj;
$proto596["m_contained"] = array();
$proto596["m_strCase"] = "";
$proto596["m_havingmode"] = "0";
$proto596["m_inBrackets"] = "0";
$proto596["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto596);

$proto594["m_joinon"] = $obj;
$obj = new SQLFromListItem($proto594);

$proto571["m_fromlist"][]=$obj;
$proto571["m_groupby"] = array();
$proto571["m_orderby"] = array();
$obj = new SQLQuery($proto571);

$queryData_commercial_invoice_items = $obj;
$tdatacommercial_invoice_items[".sqlquery"] = $queryData_commercial_invoice_items;

$tableEvents["commercial_invoice_items"] = new eventsBase;

?>
